package main

import "github.com/gin-gonic/gin"

func main() {
	r := gin.Default()

	r.GET("json", func(ctx *gin.Context) {
		ctx.JSON(200, gin.H{
			"html":   "<span>Hello World!</span>",
			"chHtml": "<span>你好 世界!</span>",
		})
	})

	r.GET("pure-json", func(ctx *gin.Context) {
		ctx.PureJSON(200, gin.H{
			"html":   "<span>Hello World!</span>",
			"chHtml": "<span>你好世界!</span>",
		})
	})
	r.Run()
}
